Ext.define("SHApp.EmployeeInfo.EducationInfo.Form", {
    extend: "BLBTSystem.Form",
    submitUrl: "api/educationinfo?format=json",
    winWidth: 615,
    winHeight: 265,
    initComponent: function () {
        Ext.apply(this);
        this.createItems();
        this.callParent(arguments);
    },
    createItems: function () {
        var me = this;
        this.items = [{
            width: 285,
            border: false,
            bodyStyle: "background:#DFE9F6",
            layout: { type: "vbox", align: "stretch" },
            items: [
				{
				    xtype: "textfield",
				    fieldLabel: "ID",
				    name: "Id",
				    hidden: true
				}, Ext.create("BLBTSystem.CmbYesNo", {
				    fieldLabel: "<span style='color:red'>*</span>教育类型",
				    fields: ["text"],
				    data: [["学历"], ["培训"]],
				    valueField: "text",
				    displayField: "text",
				    name: "EducationType",
				    maxLength: 50,
				    allowBlank: false,
				    blankText: "请选择教育类型!"
				}), Ext.create("BLBTSystem.CmbYesNo", {
				    fieldLabel: "<span style='color:red'>*</span>教育名称",
				    fields: ["text"],
				    data: [["技校"], ["职高"], ["专科"], ["本科"], ["硕士"], ["博士"], ["在职研究生"]],
				    valueField: "text",
				    displayField: "text",
				    name: "EducationName",
				    maxLength: 50,
				    allowBlank: false,
				    blankText: "请选择教育名称!"
				}), {
				    fieldLabel: "<span style='color:red'>*</span>学校",
				    allowBlank: false,
				    blankText: "请输入学校!",
				    xtype: "textfield",
				    name: "School",
				    maxLength: 50
				}, {
				    fieldLabel: "<span style='color:red'>*</span>专业",
				    allowBlank: false,
				    blankText: "请输入专业!",
				    xtype: "textfield",
				    name: "Major",
				    maxLength: 50
				}, {
				    fieldLabel: "研读时间",
				    xtype: "textfield",
				    name: "StudyTime",
				    maxLength: 50
				}]
        }, {
            width: 285,
            border: false,
            bodyStyle: "background:#DFE9F6",
            layout: { type: "vbox", align: "stretch" },
            items: [
                  {
                      fieldLabel: "证书",
                      xtype: "textfield",
                      name: "Certificate",
                      maxLength: 50
                  }, {
                      xtype: "datefield",
                      fieldLabel: "颁证日期",
                      value: new Date(),
                      name: "CertDate",
                      format: 'Y-m-d'
                  }, {
                      fieldLabel: "颁证单位",
                      xtype: "textfield",
                      name: "CertAuthority",
                      maxLength: 50
                  }, {
                      fieldLabel: "有效期",
                      xtype: "textfield",
                      name: "Period",
                      maxLength: 50
                  }, {
                      xtype: "hiddenfield",
                      name: "EmpId",
                      fieldLabel: "员工Id"

                  }, {
                      xtype: "hiddenfield",
                      name: "EmpName",
                      fieldLabel: "员工姓名"
                  }]
        }
		];
    }

})